package com.ark.frigate.spring;

import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import com.ark.frigate.spring.publisher.BusinessEventPublisher;
import com.ark.frigate.spring.publisher.MessageEventPublisher;

/**
 * @author zengweilong
 * @date 4/11/21 4:49 PM
 */
@Configuration
@ConditionalOnWebApplication
public class EventMessageConfiguration {

    @Bean
    public MessageEventPublisher messageEventPublisher() {
        return new MessageEventPublisher();
    }

    @Bean
    public BusinessEventPublisher businessEventPublisher() {
        return new BusinessEventPublisher();
    }

}
